<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>gmime-autocrypt: GMime 3.0 Reference Manual</title>
<meta name="generator" content="DocBook XSL Stylesheets V1.79.1">
<link rel="home" href="index.html" title="GMime 3.0 Reference Manual">
<link rel="up" href="core.html" title="Part III. GMime Core Reference">
<link rel="prev" href="gmime-GMimeFormatOptions.html" title="GMimeFormatOptions">
<link rel="next" href="classes.html" title="Part IV. GMime Classes">
<meta name="generator" content="GTK-Doc V1.32 (XML mode)">
<link rel="stylesheet" href="style.css" type="text/css">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table class="navigation" id="top" width="100%" summary="Navigation header" cellpadding="2" cellspacing="5"><tr valign="middle">
<td width="100%" align="left" class="shortcuts">
<a href="#" class="shortcut">Top</a><span id="nav_description">  <span class="dim">|</span> 
                  <a href="#gmime-gmime-autocrypt.description" class="shortcut">Description</a></span>
</td>
<td><a accesskey="h" href="index.html"><img src="home.png" width="16" height="16" border="0" alt="Home"></a></td>
<td><a accesskey="u" href="core.html"><img src="up.png" width="16" height="16" border="0" alt="Up"></a></td>
<td><a accesskey="p" href="gmime-GMimeFormatOptions.html"><img src="left.png" width="16" height="16" border="0" alt="Prev"></a></td>
<td><a accesskey="n" href="classes.html"><img src="right.png" width="16" height="16" border="0" alt="Next"></a></td>
</tr></table>
<div class="refentry">
<a name="gmime-gmime-autocrypt"></a><div class="titlepage"></div>
<div class="refnamediv"><table width="100%"><tr>
<td valign="top">
<h2><span class="refentrytitle"><a name="gmime-gmime-autocrypt.top_of_page"></a>gmime-autocrypt</span></h2>
<p>gmime-autocrypt</p>
</td>
<td class="gallery_image" valign="top" align="right"></td>
</tr></table></div>
<div class="refsect1">
<a name="gmime-gmime-autocrypt.functions"></a><h2>Functions</h2>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="functions_proto_type">
<col class="functions_proto_name">
</colgroup>
<tbody>
<tr>
<td class="function_type">
<a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="returnvalue">GMimeAutocryptHeader</span></a> *
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-new" title="g_mime_autocrypt_header_new ()">g_mime_autocrypt_header_new</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="returnvalue">GMimeAutocryptHeader</span></a> *
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-new-from-string" title="g_mime_autocrypt_header_new_from_string ()">g_mime_autocrypt_header_new_from_string</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="InternetAddressMailbox.html" title="InternetAddressMailbox"><span class="returnvalue">InternetAddressMailbox</span></a> *
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-get-address" title="g_mime_autocrypt_header_get_address ()">g_mime_autocrypt_header_get_address</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-set-address" title="g_mime_autocrypt_header_set_address ()">g_mime_autocrypt_header_set_address</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-set-address-from-string" title="g_mime_autocrypt_header_set_address_from_string ()">g_mime_autocrypt_header_set_address_from_string</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">const <span class="returnvalue">char</span> *
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-get-address-as-string" title="g_mime_autocrypt_header_get_address_as_string ()">g_mime_autocrypt_header_get_address_as_string</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptPreferEncrypt" title="enum GMimeAutocryptPreferEncrypt"><span class="returnvalue">GMimeAutocryptPreferEncrypt</span></a>
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-get-prefer-encrypt" title="g_mime_autocrypt_header_get_prefer_encrypt ()">g_mime_autocrypt_header_get_prefer_encrypt</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-set-prefer-encrypt" title="g_mime_autocrypt_header_set_prefer_encrypt ()">g_mime_autocrypt_header_set_prefer_encrypt</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">GBytes</span> *
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-get-keydata" title="g_mime_autocrypt_header_get_keydata ()">g_mime_autocrypt_header_get_keydata</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-set-keydata" title="g_mime_autocrypt_header_set_keydata ()">g_mime_autocrypt_header_set_keydata</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">GDateTime</span> *
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-get-effective-date" title="g_mime_autocrypt_header_get_effective_date ()">g_mime_autocrypt_header_get_effective_date</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-set-effective-date" title="g_mime_autocrypt_header_set_effective_date ()">g_mime_autocrypt_header_set_effective_date</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">gboolean</span>
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-is-complete" title="g_mime_autocrypt_header_is_complete ()">g_mime_autocrypt_header_is_complete</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">char</span> *
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-to-string" title="g_mime_autocrypt_header_to_string ()">g_mime_autocrypt_header_to_string</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">int</span>
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-compare" title="g_mime_autocrypt_header_compare ()">g_mime_autocrypt_header_compare</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-clone" title="g_mime_autocrypt_header_clone ()">g_mime_autocrypt_header_clone</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeaderList" title="struct GMimeAutocryptHeaderList"><span class="returnvalue">GMimeAutocryptHeaderList</span></a> *
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-list-new" title="g_mime_autocrypt_header_list_new ()">g_mime_autocrypt_header_list_new</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">guint</span>
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-list-add-missing-addresses" title="g_mime_autocrypt_header_list_add_missing_addresses ()">g_mime_autocrypt_header_list_add_missing_addresses</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-list-add" title="g_mime_autocrypt_header_list_add ()">g_mime_autocrypt_header_list_add</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">guint</span>
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-list-get-count" title="g_mime_autocrypt_header_list_get_count ()">g_mime_autocrypt_header_list_get_count</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="returnvalue">GMimeAutocryptHeader</span></a> *
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-list-get-header-at" title="g_mime_autocrypt_header_list_get_header_at ()">g_mime_autocrypt_header_list_get_header_at</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="returnvalue">GMimeAutocryptHeader</span></a> *
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-list-get-header-for-address" title="g_mime_autocrypt_header_list_get_header_for_address ()">g_mime_autocrypt_header_list_get_header_for_address</a> <span class="c_punctuation">()</span>
</td>
</tr>
<tr>
<td class="function_type">
<span class="returnvalue">void</span>
</td>
<td class="function_name">
<a class="link" href="gmime-gmime-autocrypt.html#g-mime-autocrypt-header-list-remove-incomplete" title="g_mime_autocrypt_header_list_remove_incomplete ()">g_mime_autocrypt_header_list_remove_incomplete</a> <span class="c_punctuation">()</span>
</td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect1">
<a name="gmime-gmime-autocrypt.other"></a><h2>Types and Values</h2>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="other_proto_type">
<col class="other_proto_name">
</colgroup>
<tbody>
<tr>
<td class="datatype_keyword">enum</td>
<td class="function_name"><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptPreferEncrypt" title="enum GMimeAutocryptPreferEncrypt">GMimeAutocryptPreferEncrypt</a></td>
</tr>
<tr>
<td class="datatype_keyword">struct</td>
<td class="function_name"><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader">GMimeAutocryptHeader</a></td>
</tr>
<tr>
<td class="datatype_keyword">struct</td>
<td class="function_name"><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeaderList" title="struct GMimeAutocryptHeaderList">GMimeAutocryptHeaderList</a></td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect1">
<a name="gmime-gmime-autocrypt.description"></a><h2>Description</h2>
</div>
<div class="refsect1">
<a name="gmime-gmime-autocrypt.functions_details"></a><h2>Functions</h2>
<div class="refsect2">
<a name="g-mime-autocrypt-header-new"></a><h3>g_mime_autocrypt_header_new ()</h3>
<pre class="programlisting"><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="returnvalue">GMimeAutocryptHeader</span></a> *
g_mime_autocrypt_header_new (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
<p>Creates a new <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> object.</p>
<div class="refsect3">
<a name="g-mime-autocrypt-header-new.returns"></a><h4>Returns</h4>
<p>a new <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> object. </p>
<p><span class="annotation">[<a href="http://foldoc.org/transfer%20full"><span class="acronym">transfer full</span></a>]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-mime-autocrypt-header-new-from-string"></a><h3>g_mime_autocrypt_header_new_from_string ()</h3>
<pre class="programlisting"><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="returnvalue">GMimeAutocryptHeader</span></a> *
g_mime_autocrypt_header_new_from_string
                               (<em class="parameter"><code>const <span class="type">char</span> *string</code></em>);</pre>
<p>Creates a new <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> object based on the value of an
Autocrypt: header.</p>
<p>Note that this will not have an <em class="parameter"><code>effective_date</code></em>
 set, since the
<em class="parameter"><code>effective_date</code></em>
 is derived from the Date: line in the same block of
e-mail headers, but cannot be extracted from the raw Autocrypt:
header itself.</p>
<div class="refsect3">
<a name="g-mime-autocrypt-header-new-from-string.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>string</p></td>
<td class="parameter_description"><p>The raw string value of an Autocrypt header</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-mime-autocrypt-header-new-from-string.returns"></a><h4>Returns</h4>
<p>a new <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> object, or
<code class="literal">NULL</code> on error. </p>
<p><span class="annotation">[<a href="http://foldoc.org/transfer%20full"><span class="acronym">transfer full</span></a>]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-mime-autocrypt-header-get-address"></a><h3>g_mime_autocrypt_header_get_address ()</h3>
<pre class="programlisting"><a class="link" href="InternetAddressMailbox.html" title="InternetAddressMailbox"><span class="returnvalue">InternetAddressMailbox</span></a> *
g_mime_autocrypt_header_get_address (<em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> *ah</code></em>);</pre>
<p>Gets the internal address of the Autocrypt header, or <code class="literal">NULL</code> if not set.</p>
<div class="refsect3">
<a name="g-mime-autocrypt-header-get-address.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>ah</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-mime-autocrypt-header-get-address.returns"></a><h4>Returns</h4>
<p>the address associated with the Autocrypt header. </p>
<p><span class="annotation">[<a href="http://foldoc.org/transfer%20none"><span class="acronym">transfer none</span></a>]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-mime-autocrypt-header-set-address"></a><h3>g_mime_autocrypt_header_set_address ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
g_mime_autocrypt_header_set_address (<em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> *ah</code></em>,
                                     <em class="parameter"><code><a class="link" href="InternetAddressMailbox.html" title="InternetAddressMailbox"><span class="type">InternetAddressMailbox</span></a> *address</code></em>);</pre>
<p>Set the address associated with the autocrypt_header.</p>
<div class="refsect3">
<a name="g-mime-autocrypt-header-set-address.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>ah</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>address</p></td>
<td class="parameter_description"><p>a <a class="link" href="InternetAddressMailbox.html" title="InternetAddressMailbox"><span class="type">InternetAddressMailbox</span></a> value</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-mime-autocrypt-header-set-address-from-string"></a><h3>g_mime_autocrypt_header_set_address_from_string ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
g_mime_autocrypt_header_set_address_from_string
                               (<em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> *ah</code></em>,
                                <em class="parameter"><code>const <span class="type">char</span> *address</code></em>);</pre>
<p>Set the address associated with the autocrypt_header.</p>
<div class="refsect3">
<a name="g-mime-autocrypt-header-set-address-from-string.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>ah</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>address</p></td>
<td class="parameter_description"><p>a <code class="literal">NULL</code>-terminated string that is a raw e-mail address</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-mime-autocrypt-header-get-address-as-string"></a><h3>g_mime_autocrypt_header_get_address_as_string ()</h3>
<pre class="programlisting">const <span class="returnvalue">char</span> *
g_mime_autocrypt_header_get_address_as_string
                               (<em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> *ah</code></em>);</pre>
<p>Gets the internal address of the Autocrypt header as a C string, or <code class="literal">NULL</code> if not set.</p>
<div class="refsect3">
<a name="g-mime-autocrypt-header-get-address-as-string.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>ah</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-mime-autocrypt-header-get-address-as-string.returns"></a><h4>Returns</h4>
<p>the address associated with the Autocrypt header. </p>
<p><span class="annotation">[<a href="http://foldoc.org/transfer%20none"><span class="acronym">transfer none</span></a>]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-mime-autocrypt-header-get-prefer-encrypt"></a><h3>g_mime_autocrypt_header_get_prefer_encrypt ()</h3>
<pre class="programlisting"><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptPreferEncrypt" title="enum GMimeAutocryptPreferEncrypt"><span class="returnvalue">GMimeAutocryptPreferEncrypt</span></a>
g_mime_autocrypt_header_get_prefer_encrypt
                               (<em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> *ah</code></em>);</pre>
<p>Gets the encryption preference stated by the Autocrypt header.</p>
<div class="refsect3">
<a name="g-mime-autocrypt-header-get-prefer-encrypt.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>ah</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-mime-autocrypt-header-get-prefer-encrypt.returns"></a><h4>Returns</h4>
<p> the encryption preference associated with the Autocrypt header</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-mime-autocrypt-header-set-prefer-encrypt"></a><h3>g_mime_autocrypt_header_set_prefer_encrypt ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
g_mime_autocrypt_header_set_prefer_encrypt
                               (<em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> *ah</code></em>,
                                <em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptPreferEncrypt" title="enum GMimeAutocryptPreferEncrypt"><span class="type">GMimeAutocryptPreferEncrypt</span></a> pref</code></em>);</pre>
<p>Set the encryption preference associated with the Autocrypt header.</p>
<div class="refsect3">
<a name="g-mime-autocrypt-header-set-prefer-encrypt.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>ah</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>pref</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptPreferEncrypt" title="enum GMimeAutocryptPreferEncrypt"><span class="type">GMimeAutocryptPreferEncrypt</span></a> value</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-mime-autocrypt-header-get-keydata"></a><h3>g_mime_autocrypt_header_get_keydata ()</h3>
<pre class="programlisting"><span class="returnvalue">GBytes</span> *
g_mime_autocrypt_header_get_keydata (<em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> *ah</code></em>);</pre>
<p>Gets the raw keydata of the Autocrypt header, or <code class="literal">NULL</code> if not set.</p>
<div class="refsect3">
<a name="g-mime-autocrypt-header-get-keydata.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>ah</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-mime-autocrypt-header-get-keydata.returns"></a><h4>Returns</h4>
<p>the raw key data associated with the Autocrypt header. </p>
<p><span class="annotation">[<a href="http://foldoc.org/transfer%20none"><span class="acronym">transfer none</span></a>]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-mime-autocrypt-header-set-keydata"></a><h3>g_mime_autocrypt_header_set_keydata ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
g_mime_autocrypt_header_set_keydata (<em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> *ah</code></em>,
                                     <em class="parameter"><code><span class="type">GBytes</span> *data</code></em>);</pre>
<p>Set the raw key data associated with the Autocrypt header.</p>
<div class="refsect3">
<a name="g-mime-autocrypt-header-set-keydata.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>ah</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>keydata</p></td>
<td class="parameter_description"><p>a <span class="type">GBytes</span> object</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-mime-autocrypt-header-get-effective-date"></a><h3>g_mime_autocrypt_header_get_effective_date ()</h3>
<pre class="programlisting"><span class="returnvalue">GDateTime</span> *
g_mime_autocrypt_header_get_effective_date
                               (<em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> *ah</code></em>);</pre>
<p>Gets the effective date of the Autocrypt header, or <code class="literal">NULL</code> if not set.</p>
<div class="refsect3">
<a name="g-mime-autocrypt-header-get-effective-date.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>ah</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-mime-autocrypt-header-get-effective-date.returns"></a><h4>Returns</h4>
<p>the effective date associated with the Autocrypt header. </p>
<p><span class="annotation">[<a href="http://foldoc.org/transfer%20none"><span class="acronym">transfer none</span></a>]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-mime-autocrypt-header-set-effective-date"></a><h3>g_mime_autocrypt_header_set_effective_date ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
g_mime_autocrypt_header_set_effective_date
                               (<em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> *ah</code></em>,
                                <em class="parameter"><code><span class="type">GDateTime</span> *effective_date</code></em>);</pre>
<p>Set the effective date associated with the Autocrypt header.</p>
<div class="refsect3">
<a name="g-mime-autocrypt-header-set-effective-date.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>ah</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>effective_date</p></td>
<td class="parameter_description"><p>a <span class="type">GDateTime</span> object</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-mime-autocrypt-header-is-complete"></a><h3>g_mime_autocrypt_header_is_complete ()</h3>
<pre class="programlisting"><span class="returnvalue">gboolean</span>
g_mime_autocrypt_header_is_complete (<em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> *ah</code></em>);</pre>
<p>When dealing with Autocrypt headers derived from a message, some
sender addresses will not have a legitimate/complete header
associated with them.  When a given sender address has no complete
header of a specific type, it should "reset" the state of the
associated address.</p>
<div class="refsect3">
<a name="g-mime-autocrypt-header-is-complete.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>ah</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-mime-autocrypt-header-is-complete.returns"></a><h4>Returns</h4>
<p> <code class="literal">TRUE</code> if the header is complete, or <code class="literal">FALSE</code> if it is incomplete.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-mime-autocrypt-header-to-string"></a><h3>g_mime_autocrypt_header_to_string ()</h3>
<pre class="programlisting"><span class="returnvalue">char</span> *
g_mime_autocrypt_header_to_string (<em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> *ah</code></em>,
                                   <em class="parameter"><code><span class="type">gboolean</span> gossip</code></em>);</pre>
<p>Gets the string representation of the Autocrypt header, or <code class="literal">NULL</code> on
error.  For example, it might return:</p>
<p>    prefer-encrypt=mutual; addr=bob@example.com; keydata=AAAB15BE...</p>
<p>If you are using this object to populate an Autocrypt-Gossip
header, you should set <em class="parameter"><code>gossip</code></em>
 to <code class="literal">TRUE</code> (this will suppress
inclusion of prefer-encrypt).</p>
<div class="refsect3">
<a name="g-mime-autocrypt-header-to-string.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>ah</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>gossip</p></td>
<td class="parameter_description"><p>a <span class="type">gboolean</span>, indicating whether this header is for use with gossip</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-mime-autocrypt-header-to-string.returns"></a><h4>Returns</h4>
<p>the string representation of the
Autocrypt header. </p>
<p><span class="annotation">[<a href="http://foldoc.org/transfer%20full"><span class="acronym">transfer full</span></a>]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-mime-autocrypt-header-compare"></a><h3>g_mime_autocrypt_header_compare ()</h3>
<pre class="programlisting"><span class="returnvalue">int</span>
g_mime_autocrypt_header_compare (<em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> *ah1</code></em>,
                                 <em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> *ah2</code></em>);</pre>
<p>Compare two Autocrypt Headers.  This is useful for comparison, as well as for
sorting headers by:</p>
<div class="itemizedlist"><ul class="itemizedlist" style="list-style-type: disc; ">
<li class="listitem"><p>address</p></li>
<li class="listitem"><p>effective_date</p></li>
<li class="listitem"><p>keydata</p></li>
<li class="listitem"><p>prefer_encrypt</p></li>
</ul></div>
<div class="refsect3">
<a name="g-mime-autocrypt-header-compare.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>ah1</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>ah2</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-mime-autocrypt-header-compare.returns"></a><h4>Returns</h4>
<p> -1, 0, or 1 when <em class="parameter"><code>ah1</code></em>
is less than, equal to, or greater than <em class="parameter"><code>ah2</code></em>
.</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-mime-autocrypt-header-clone"></a><h3>g_mime_autocrypt_header_clone ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
g_mime_autocrypt_header_clone (<em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> *dst</code></em>,
                               <em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> *src</code></em>);</pre>
<p>If address and type already match between <em class="parameter"><code>src</code></em>
 and <em class="parameter"><code>dst</code></em>
, copy
keydata, prefer_encrypt, effective_date from <em class="parameter"><code>src</code></em>
 to <em class="parameter"><code>dst</code></em>
.</p>
<div class="refsect3">
<a name="g-mime-autocrypt-header-clone.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>dst</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>src</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-mime-autocrypt-header-list-new"></a><h3>g_mime_autocrypt_header_list_new ()</h3>
<pre class="programlisting"><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeaderList" title="struct GMimeAutocryptHeaderList"><span class="returnvalue">GMimeAutocryptHeaderList</span></a> *
g_mime_autocrypt_header_list_new (<em class="parameter"><code><span class="type">void</span></code></em>);</pre>
<p>Creates a new <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeaderList" title="struct GMimeAutocryptHeaderList"><span class="type">GMimeAutocryptHeaderList</span></a> object.</p>
<div class="refsect3">
<a name="g-mime-autocrypt-header-list-new.returns"></a><h4>Returns</h4>
<p>a new <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeaderList" title="struct GMimeAutocryptHeaderList"><span class="type">GMimeAutocryptHeaderList</span></a> object. </p>
<p><span class="annotation">[<a href="http://foldoc.org/transfer%20full"><span class="acronym">transfer full</span></a>]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-mime-autocrypt-header-list-add-missing-addresses"></a><h3>g_mime_autocrypt_header_list_add_missing_addresses ()</h3>
<pre class="programlisting"><span class="returnvalue">guint</span>
g_mime_autocrypt_header_list_add_missing_addresses
                               (<em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeaderList" title="struct GMimeAutocryptHeaderList"><span class="type">GMimeAutocryptHeaderList</span></a> *list</code></em>,
                                <em class="parameter"><code><a class="link" href="InternetAddressList.html" title="InternetAddressList"><span class="type">InternetAddressList</span></a> *addresses</code></em>);</pre>
<p>Adds a new incomplete <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> object for each
InternetAddressMailbox found in <span class="type">addresses</span>.</p>
<div class="refsect3">
<a name="g-mime-autocrypt-header-list-add-missing-addresses.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>list</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeaderList" title="struct GMimeAutocryptHeaderList"><span class="type">GMimeAutocryptHeaderList</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>addresses</p></td>
<td class="parameter_description"><p>an <a class="link" href="InternetAddressList.html" title="InternetAddressList"><span class="type">InternetAddressList</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-mime-autocrypt-header-list-add-missing-addresses.returns"></a><h4>Returns</h4>
<p> the number of addresses added</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-mime-autocrypt-header-list-add"></a><h3>g_mime_autocrypt_header_list_add ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
g_mime_autocrypt_header_list_add (<em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeaderList" title="struct GMimeAutocryptHeaderList"><span class="type">GMimeAutocryptHeaderList</span></a> *list</code></em>,
                                  <em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> *header</code></em>);</pre>
<p>Adds a the passed <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> to the list.</p>
<div class="refsect3">
<a name="g-mime-autocrypt-header-list-add.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>list</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeaderList" title="struct GMimeAutocryptHeaderList"><span class="type">GMimeAutocryptHeaderList</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>header</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="type">GMimeAutocryptHeader</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-mime-autocrypt-header-list-get-count"></a><h3>g_mime_autocrypt_header_list_get_count ()</h3>
<pre class="programlisting"><span class="returnvalue">guint</span>
g_mime_autocrypt_header_list_get_count
                               (<em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeaderList" title="struct GMimeAutocryptHeaderList"><span class="type">GMimeAutocryptHeaderList</span></a> *list</code></em>);</pre>
<p>See how many Autocrypt headers are in the list.</p>
<div class="refsect3">
<a name="g-mime-autocrypt-header-list-get-count.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>list</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeaderList" title="struct GMimeAutocryptHeaderList"><span class="type">GMimeAutocryptHeaderList</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-mime-autocrypt-header-list-get-count.returns"></a><h4>Returns</h4>
<p> the number of available Autocrypt headers</p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-mime-autocrypt-header-list-get-header-at"></a><h3>g_mime_autocrypt_header_list_get_header_at ()</h3>
<pre class="programlisting"><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="returnvalue">GMimeAutocryptHeader</span></a> *
g_mime_autocrypt_header_list_get_header_at
                               (<em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeaderList" title="struct GMimeAutocryptHeaderList"><span class="type">GMimeAutocryptHeaderList</span></a> *list</code></em>,
                                <em class="parameter"><code><span class="type">guint</span> index</code></em>);</pre>
<p>Get the Nth header in the list (returns <code class="literal">NULL</code> on error, or if <em class="parameter"><code>index</code></em>
 is out of bounds)</p>
<div class="refsect3">
<a name="g-mime-autocrypt-header-list-get-header-at.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>list</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeaderList" title="struct GMimeAutocryptHeaderList"><span class="type">GMimeAutocryptHeaderList</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>index</p></td>
<td class="parameter_description"><p>an index into the list</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-mime-autocrypt-header-list-get-header-at.returns"></a><h4>Returns</h4>
<p>a pointer to the Nth header in the list. </p>
<p><span class="annotation">[<a href="http://foldoc.org/transfer%20none"><span class="acronym">transfer none</span></a>]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-mime-autocrypt-header-list-get-header-for-address"></a><h3>g_mime_autocrypt_header_list_get_header_for_address ()</h3>
<pre class="programlisting"><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeader" title="struct GMimeAutocryptHeader"><span class="returnvalue">GMimeAutocryptHeader</span></a> *
g_mime_autocrypt_header_list_get_header_for_address
                               (<em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeaderList" title="struct GMimeAutocryptHeaderList"><span class="type">GMimeAutocryptHeaderList</span></a> *list</code></em>,
                                <em class="parameter"><code><a class="link" href="InternetAddressMailbox.html" title="InternetAddressMailbox"><span class="type">InternetAddressMailbox</span></a> *mailbox</code></em>);</pre>
<p>Gets the Autocrypt header corresponding to the given <em class="parameter"><code>mailbox</code></em>
.</p>
<div class="refsect3">
<a name="g-mime-autocrypt-header-list-get-header-for-address.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody>
<tr>
<td class="parameter_name"><p>list</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeaderList" title="struct GMimeAutocryptHeaderList"><span class="type">GMimeAutocryptHeaderList</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr>
<tr>
<td class="parameter_name"><p>mailbox</p></td>
<td class="parameter_description"><p>an <a class="link" href="InternetAddressMailbox.html" title="InternetAddressMailbox"><span class="type">InternetAddressMailbox</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
<div class="refsect3">
<a name="g-mime-autocrypt-header-list-get-header-for-address.returns"></a><h4>Returns</h4>
<p>a pointer to the header in the list which
matches the requested address, or <code class="literal">NULL</code> if no such header exists in
the list. </p>
<p><span class="annotation">[<a href="http://foldoc.org/transfer%20none"><span class="acronym">transfer none</span></a>]</span></p>
</div>
</div>
<hr>
<div class="refsect2">
<a name="g-mime-autocrypt-header-list-remove-incomplete"></a><h3>g_mime_autocrypt_header_list_remove_incomplete ()</h3>
<pre class="programlisting"><span class="returnvalue">void</span>
g_mime_autocrypt_header_list_remove_incomplete
                               (<em class="parameter"><code><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeaderList" title="struct GMimeAutocryptHeaderList"><span class="type">GMimeAutocryptHeaderList</span></a> *list</code></em>);</pre>
<p>Remove all incomplete Autocrypt headers from the list.</p>
<div class="refsect3">
<a name="g-mime-autocrypt-header-list-remove-incomplete.parameters"></a><h4>Parameters</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="150px" class="parameters_name">
<col class="parameters_description">
<col width="200px" class="parameters_annotations">
</colgroup>
<tbody><tr>
<td class="parameter_name"><p>list</p></td>
<td class="parameter_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptHeaderList" title="struct GMimeAutocryptHeaderList"><span class="type">GMimeAutocryptHeaderList</span></a> object</p></td>
<td class="parameter_annotations"> </td>
</tr></tbody>
</table></div>
</div>
</div>
</div>
<div class="refsect1">
<a name="gmime-gmime-autocrypt.other_details"></a><h2>Types and Values</h2>
<div class="refsect2">
<a name="GMimeAutocryptPreferEncrypt"></a><h3>enum GMimeAutocryptPreferEncrypt</h3>
<p>A description of the user's preference for encrypted messaging.</p>
<div class="refsect3">
<a name="GMimeAutocryptPreferEncrypt.members"></a><h4>Members</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="300px" class="enum_members_name">
<col class="enum_members_description">
<col width="200px" class="enum_members_annotations">
</colgroup>
<tbody>
<tr>
<td class="enum_member_name"><p><a name="GMIME-AUTOCRYPT-PREFER-ENCRYPT-NONE:CAPS"></a>GMIME_AUTOCRYPT_PREFER_ENCRYPT_NONE</p></td>
<td class="enum_member_description">
<p>No preference stated.</p>
</td>
<td class="enum_member_annotations"> </td>
</tr>
<tr>
<td class="enum_member_name"><p><a name="GMIME-AUTOCRYPT-PREFER-ENCRYPT-MUTUAL:CAPS"></a>GMIME_AUTOCRYPT_PREFER_ENCRYPT_MUTUAL</p></td>
<td class="enum_member_description">
<p>Please encrypt, if you also have this preference</p>
</td>
<td class="enum_member_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
</div>
<hr>
<div class="refsect2">
<a name="GMimeAutocryptHeader"></a><h3>struct GMimeAutocryptHeader</h3>
<pre class="programlisting">struct GMimeAutocryptHeader {
	GObject parent_object;

	InternetAddressMailbox *address;
	GMimeAutocryptPreferEncrypt prefer_encrypt;
	GBytes *keydata;
	GDateTime *effective_date;
};
</pre>
<p>An object containing Autocrypt information about a given e-mail
address, as derived from a message header.</p>
<p>See https://autocrypt.org/ for details and motivation.</p>
<div class="refsect3">
<a name="GMimeAutocryptHeader.members"></a><h4>Members</h4>
<div class="informaltable"><table class="informaltable" width="100%" border="0">
<colgroup>
<col width="300px" class="struct_members_name">
<col class="struct_members_description">
<col width="200px" class="struct_members_annotations">
</colgroup>
<tbody>
<tr>
<td class="struct_member_name"><p><span class="type">GObject</span> <em class="structfield"><code><a name="GMimeAutocryptHeader.parent-object"></a>parent_object</code></em>;</p></td>
<td class="struct_member_description"><p>parent <span class="type">GObject</span></p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><a class="link" href="InternetAddressMailbox.html" title="InternetAddressMailbox"><span class="type">InternetAddressMailbox</span></a> *<em class="structfield"><code><a name="GMimeAutocryptHeader.address"></a>address</code></em>;</p></td>
<td class="struct_member_description"><p>the <a class="link" href="InternetAddressMailbox.html" title="InternetAddressMailbox"><span class="type">InternetAddressMailbox</span></a> associated with this Autocrypt header.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptPreferEncrypt" title="enum GMimeAutocryptPreferEncrypt"><span class="type">GMimeAutocryptPreferEncrypt</span></a> <em class="structfield"><code><a name="GMimeAutocryptHeader.prefer-encrypt"></a>prefer_encrypt</code></em>;</p></td>
<td class="struct_member_description"><p>a <a class="link" href="gmime-gmime-autocrypt.html#GMimeAutocryptPreferEncrypt" title="enum GMimeAutocryptPreferEncrypt"><span class="type">GMimeAutocryptPreferEncrypt</span></a> value (defaults to <em class="parameter"><code>GMIME_AUTOCRYPT_PREFER_ENCRYPT_NONE</code></em>
).</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><span class="type">GBytes</span> *<em class="structfield"><code><a name="GMimeAutocryptHeader.keydata"></a>keydata</code></em>;</p></td>
<td class="struct_member_description"><p>the raw binary form of the encoded key.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
<tr>
<td class="struct_member_name"><p><span class="type">GDateTime</span> *<em class="structfield"><code><a name="GMimeAutocryptHeader.effective-date"></a>effective_date</code></em>;</p></td>
<td class="struct_member_description"><p>the date associated with the Autocrypt header in this message.</p></td>
<td class="struct_member_annotations"> </td>
</tr>
</tbody>
</table></div>
</div>
</div>
<hr>
<div class="refsect2">
<a name="GMimeAutocryptHeaderList"></a><h3>struct GMimeAutocryptHeaderList</h3>
<pre class="programlisting">struct GMimeAutocryptHeaderList {
	GObject parent_object;
};
</pre>
<p>A list of Autocrypt headers, typically extracted from a GMimeMessage.</p>
</div>
</div>
</div>
<div class="footer">
<hr>Generated by GTK-Doc V1.32</div>
</body>
</html>